{{! corresponding files: elements.php & elements.json }}

<!-- /* Sub Nav */ -->
<header class="page-header">
<div class="pure-u-1 pure-u-md-7-24">
<h4 class="page-title">{{copy_embed_title}} {{#selected_campaign}}<span class="fadedtext">({{element_count}})</span>{{/selected_campaign}}</h4>
</div><!--pure-->

<div class="pure-u-1 pure-u-md-17-24">
<ul class="inline-subnav">
	<li><a href="{{www_path}}/">{{copy_activity_subnav}}</a></li>
	<li><a class="current" href="{{www_path}}/elements/">{{copy_elements_subnav}}</a></li>
	<li><a href="{{www_path}}/page/">{{user_page_display_uri}}</a></li>
</ul>
</div><!--pure-->
</header>

<!--/* Campaigns */-->
<div id="campaigns">
	<div class="pure-u-1 pure-u-md-2-3">
		<div class="selecta">
			<form accept-charset="UTF-8" method="post" action="{{www_path}}/elements/">
				<label for="current-campaign">{{label_selected_campaign}}</label>
				<select name="current-campaign" id="current-campaign">
					<option value="-1" selected="selected">No campaign</option>
					{{{campaigns_as_options}}}
				</select>
			</form>
		</div><!--selecta-->
			{{#show_edit}}
			<a class="lightboxed edit-button" title="{{copy_editcampaign_desc}}" href="{{www_path}}/campaigns/edit/{{selected_campaign}}"><span class="icon icon-pencil"></span><!--icon--></a>
			{{/show_edit}}
			<a class="lightboxed edit-button" title="{{copy_addcampaign_desc}}" href="{{www_path}}/campaigns/add/"><span class="icon icon-plus"></span><!--icon--></a>
	</div>
	<div class="pure-u-1 pure-u-md-1-3 alignright">
		<a href="{{www_path}}/elements/add/" class="noelement button lightboxed store"><div class="icon icon-plus"></div><!--icon-->{{copy_element_add}}</a><!--noelement-->
	</div><!--pure-->


{{#show_first_use}}
<div class="pure-u-1">
	<div class="alt callout">
		<div class="callout-inner">
			<h3>{{copy_get_started_title}}</h3>
			<p>{{copy_get_started_body}}</p>
			<p><a class="lightboxed" href="{{www_path}}/campaigns/add/">{{copy_add_campaign_to_start}}</a> {{copy_get_started_body_2}}
			<a class="add lightboxed store" href="{{www_path}}/elements/add/">{{copy_add_element_to_start}}</a>.</p>
		</div><!--callout-inner-->
	</div><!--callout-->
</div><!--pure-->
{{/show_first_use}}

{{#selected_campaign}}
<div class="campaign-elements">
	{{#elements_for_campaign}}
	<ul class="alternating">
		{{#elements_for_campaign}}
		<li class="pure-u-1 pure-u-md-1-2">
		<a class="primary" href="{{www_path}}/elements/edit/{{id}}">
		<span class="element-title">{{name}}</span>
		<span class="descriptive spaced fadedtext">{{type}}</span></a>
		<a class="ql copy" title="Copy quick embed code" data-clipboard-text="&lt;script src=&quot;{{public_url}}/cashmusic.js&quot; data-element=&quot;{{id}}&quot;&gt;&lt;/script&gt;" ><div class="icon icon-share"></div><!--icon--></a>
			<div class="more"><div class="toggle"></div><!--toggle-->
				<div class="actions">
					<div class="action-inner">
						<a href="{{www_path}}/elements/edit/{{id}}" class="mininav_flush"><div class="icon icon-pencil"></div><!--icon--> {{copy_edit}}</a>
						<a href="{{www_path}}/elements/delete/{{id}}" class="mininav_flush needsconfirmation delete"><div class="icon icon-ban"></div><!--icon--> {{copy_delete}}</a>
					</div><!--action-inner-->
				</div><!--actions-->
			</div><!--more-->
		</li>
		{{/elements_for_campaign}}
	</ul>
	{{/elements_for_campaign}}
</div><!--campiagn-elements-->

	{{^elements_for_campaign}}
	<div class="empty"><p>{{copy_no_elements_in_campaign}}</p></div>
	{{/elements_for_campaign}}

{{/selected_campaign}}
